package com.jci.vsd.activity.enterprise;

import android.content.Context;
import android.os.Bundle;
import android.view.View;
import android.widget.EditText;
import android.widget.ImageButton;
import android.widget.TextView;

import com.jci.vsd.R;
import com.jci.vsd.activity.BaseActivity;
import com.jci.vsd.bean.enterprise.DepartmentBean;
import com.jci.vsd.constant.AppConstant;
import java.util.ArrayList;
import java.util.List;
import butterknife.BindView;

/**
 * Created by liqing on 18/7/2.
 * 部门详情
 */

public class DepartmentDetailActivity extends BaseActivity {

    List<String> allStatus;
    @BindView(R.id.edt_depart_name)
    EditText edtDepartName;
    @BindView(R.id.edt_limit)
    EditText edtLimit;

    @BindView(R.id.tv_reim_authority)
    TextView tvReimAuthority;

    @BindView(R.id.tv_depart_leader)
    TextView tvDepartLeader;

    @BindView(R.id.tv_add)
    TextView tvAdd;
    @BindView(R.id.button_back)
    ImageButton backBtn;
    @BindView(R.id.textview_title)
    TextView titleTxt;
    private DepartmentBean bean;//部门bean
    private Context mContext;


    @Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_department_detail);
        mContext = DepartmentDetailActivity.this;
        allStatus = new ArrayList<>();
        initViewEvent();
        bean = (DepartmentBean) getIntent().getSerializableExtra(AppConstant.SERIAL_KEY);
        if (bean != null) {
            edtDepartName.setText(bean.getName());
            tvReimAuthority.setText(bean.getPermname());
            tvDepartLeader.setText(bean.getLname());
        }

    }




    @Override
    public void onClick(View view) {
        super.onClick(view);

    }


    @Override
    protected void initViewEvent() {
        tvDepartLeader.setOnClickListener(this);
        tvReimAuthority.setOnClickListener(this);
        tvAdd.setOnClickListener(this);
        backBtn.setOnClickListener(this);
        titleTxt.setText(getResources().getString(R.string.department_detail));
    }


}
